package com.naiterui.ehp.bs.doctor.service;

import java.util.List;
import java.util.Map;

import com.naiterui.common.repository.page.PageParamVO;
import com.naiterui.common.repository.page.PageVO;
import com.naiterui.ehp.bp.bo.consult.CommentBO;
import com.naiterui.ehp.bp.bo.consult.CommentDetailBO;
import com.naiterui.ehp.bp.support.exception.BusinessException;
import com.naiterui.ehp.bs.doctor.vo.patient.ConsultCommentVO;

/**
 * @Description 会话评价
 * @Author gongbaoqiang
 * @Date 2020/6/30 7:24 PM
 */
public interface IConsultCommentService {

    /**
     * 查询医生评价
     * @param doctorId
     * @param pageParamVO
     * @return
     * @throws BusinessException
     */
    PageVO<CommentDetailBO> findByDoctorId(Long doctorId, PageParamVO pageParamVO) throws BusinessException;

    /**
     * 获取评价内容
     * @param commentId
     * @return
     * @throws BusinessException
     */
    ConsultCommentVO getDetail(Long commentId) throws BusinessException;

    /**
     * 提价评价
     * @param commentBO
     * @throws BusinessException
     */
    Long submit(CommentBO commentBO) throws BusinessException;


    /**
     * 回复评价
     * @param commentId
     * @param content
     * @throws BusinessException
     */
    void replay(Long commentId, String content) throws BusinessException;

    /**
     * 获取医生好评率
     * @param doctorIds
     * @return
     */
    Map<Long, String> getApplauseRate(List<Long> doctorIds);

    /**
     * 判断会话是否已做过评价
     * @return
     * @throws BusinessException
     */
    Boolean existByConsultSession(Long consultSessionId, Integer consultType) throws BusinessException;

    /**
     * 获取评价详情
     * 
     * @param consultSessionId
     * @param consultType
     * @return
     */
    CommentDetailBO getConsultSessionCommont(Long consultSessionId, Integer consultType);
}
